/** Part of Zombie Navigator
	Copyright © 2016  Zombie Navigator Developers
	
	@file
	@module
	@license AGPL-3.0+
	
*/ 'use strict';


/* Used modules */
const _iDownloads = require('./dl/downloads');
const _pLogger = require('./logger');


/* Internal APIs */

/**
	@public
	@returns {Promise} path
*/
const download = (uri, suggestedName, isPrivate, referrer) => {
	const iDownloads = _iDownloads;
	const pLogger = _pLogger;
	
	pLogger.debug('Downloading:', {uri: uri, suggestedName: suggestedName, isPrivate: isPrivate, referrer: referrer});
	return iDownloads.initiateDownload(uri, suggestedName, isPrivate, referrer);
};


/* Exports */
exports.download = download;

// vim: ts=4 noet ai

